/**
 * Copyright &copy; 2012-2017 <a href="https://vivo.com">vivo</a> All rights reserved.
 */
package com.vivo.employee.service;

import java.util.List;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.thinkgem.jeesite.common.persistence.Page;
import com.thinkgem.jeesite.common.service.CrudService;
import com.vivo.employee.entity.Ypgw;
import com.vivo.employee.dao.YpgwDao;

/**
 * 应聘岗位Service
 * @author jyangye
 * @version 2018-02-08
 */
@Service
@Transactional(readOnly = true)
public class YpgwService extends CrudService<YpgwDao, Ypgw> {

	public Ypgw get(String id) {
		return super.get(id);
	}
	
	public List<Ypgw> findList(Ypgw ypgw) {
	    ypgw.getSqlMap().put("dsf", dataScopeFilterByCompany(ypgw.getCurrentUser(), "a"));
		return super.findList(ypgw);
	}
	
	public Page<Ypgw> findPage(Page<Ypgw> page, Ypgw ypgw) {
        ypgw.getSqlMap().put("dsf", dataScopeFilterByCompany(ypgw.getCurrentUser(), "a"));
		return super.findPage(page, ypgw);
	}
	
	@Transactional(readOnly = false)
	public void save(Ypgw ypgw) {
		super.save(ypgw);
	}
	
	@Transactional(readOnly = false)
	public void delete(Ypgw ypgw) {
		super.delete(ypgw);
	}
	
}